package com.scujj.cs6.model.dto.user;

import io.swagger.v3.oas.annotations.media.Schema;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;

/**
 * 用户登录 DTO (手机号登录)
 */
@Data
@Schema(name = "用户手机号登录信息", description = "用户手机号登录信息")
public class UserPhoneLoginDTO {
    @Schema(description = "手机号", example = "13800138000")
    @NotBlank(message = "手机号不能为空")
    @Size(min = 11, max = 11, message = "手机号格式错误")
    private String phone;

    @Schema(description = "密码", example = "P@ssw0rd")
    @NotBlank(message = "密码不能为空")
    @Size(min = 6, max = 20, message = "密码长度必须在 6-20 位之间")
    private String password;
}